#define  _CRT_SECURE_NO_WARNINGS

#include"string.h"

namespace bit
{
	void test_string1()
	{

		string s1("hello word");

		string::iterator it1 = s1.begin();
		while (it1 != s1.end())
		{
			cout << *it1 << ' ';
			it1++;
		}
		cout << endl;
	}

	void test_string2()
	{
		string s1("hello word");
		s1.push_back('x');
		cout << s1.c_str() << endl;

	}

	void test_string3()
	{
		const string s1("hello word");
		string s2(s1);

		string s3 = s1;
		for (size_t i = 0; i < s1.size(); i++)
		{
			s1[i];
		}
		cout << s1.c_str() << endl;
	}

	void test_string4()
	{
		string s1("hello word");
		s1.insert(6, 'x');
		cout << s1.c_str() << endl;
	}
}



int main()
{
	bit::test_string4();
	return 0;
}